UXarray logo

Data Visualization

In this tutorial, you’ll learn:

  • TODO:

Prerequisites

Concepts

Importance

Notes

Link to Pre-Req

Necessary

  • Time to learn: x minutes


Introduction

The previous section showcased how to visualize the geometry of unstructured grids by using the Grid data structure. In this section, we will now visualize data variables that reside on unstructured elements

Data Mapping

Data variables that reside on unstructured grids can be mapped to different geometries, which impacts the choice of visualization method.

Face (Cell) Centered

Node (Vertex) Centered

Edge Centered

import uxarray as ux
grid_path = "../../meshfiles/oQU480.grid.nc"
data_path = "../../meshfiles/oQU480.data.nc"

uxds = ux.open_dataset(grid_path, data_path)

Plotting Accessor

uxds["bottomDepth"].plot()

Polygons

uxds["bottomDepth"].plot.polygons()

Points

uxds["bottomDepth"].plot.points()
import cartopy.crs as ccrs
uxds["bottomDepth"].plot(projection=ccrs.NearsidePerspective(-90, 40))
uxds["bottomDepth"].plot(projection=ccrs.Orthographic(-90, 40))